package com.atguigu.gulimall.auth.config;

import org.springframework.web.servlet.config.annotation.ViewControllerRegistry;
import org.springframework.web.servlet.config.annotation.WebMvcConfigurer;

import java.rmi.registry.Registry;

/**
 * @description: 视图映射
 * @author: BlueSky
 * @create: 2021-09-20 09:14
 **/
public class GulimallWebConfig implements WebMvcConfigurer {

	@Override
	public void addViewControllers(ViewControllerRegistry registry){
		/**
		 * @GetMapping("/login.html")
		 *
		 * 		public String regist(){
		 *			return "login";
		 * 		}
		 *
		 */

		registry.addViewController("/login.html").setViewName("login");
		registry.addViewController("/reg.html").setViewName("reg");
	}

}
